package com.docjohnson.pamphlet.views;

import android.content.Context;
import android.util.AttributeSet;
import android.widget.VideoView;

public class VideoPlayer extends VideoView {

    public VideoPlayer(Context context) {
        super(context);
    }

    public VideoPlayer(Context context, AttributeSet attrs) {
        this(context, attrs, 0);
    }

    public VideoPlayer(Context context, AttributeSet attrs, int defStyle) {
        super(context, attrs, defStyle);
    }

    @Override
    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec)
    {
        setMeasuredDimension(900, 600);
    }

    public void changeVideoSize()
    {
        getHolder().setFixedSize(800, 600);


//        forceLayout();

        requestLayout();
        invalidate();
    }
}
